home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Modules / BackSpaceModules / Source / MartinView / MartinView.h < prev    next >
Text File  |  1992-11-03  |  3KB  |  118 lines

  1. #import <appkit/View.h>
  2.  
  3. #define Martin1 0
  4. #define Martin2 1
  5. #define Ejk1 2
  6. #define Ejk2 3
  7. #define Nfunc 4    // The number of functions supported
  8.  
  9. #define Min(x,y) ((x < y)?x:y)
  10. #define Max(x,y) ((x > y)?x:y)
  11.  
  12. #define Ranf() (double)((Ranfseed=(Ranfseed*1629+1)%1048576)/1048576.)
  13. #define Ranfset(l) (Ranfseed=(((abs(l)%1048576)*1629)+1)%1048576)
  14.  
  15. #define    DEFAULTNUMCOLORS    14
  16.  
  17. #define    MAXDYNAMPOINTS    900   
  18. #define    STARTDYNAMPOINTS    400
  19.  
  20. @interface MartinView:View
  21. {
  22.     int numPixels;            // number of pixels in buffer to be displayed 
  23.     NXRect    *pixels;
  24.     char    file[FILENAME_MAX];
  25.     NXColor *colors, currColor;
  26.     id  myPrefPanel;        // Preferences Panel
  27.     id  smallInspect;       // Dummy inspector that shows up in the standard settings panel
  28.     id    maxTotalPts;
  29.     id    maxTotFlag;
  30.     id    maxInRangePts;
  31.     id    maxInFlag;
  32.     id    dynamFlush;
  33.     id    hopAField;
  34.     id    hopBField;
  35.     id    hopCField;
  36.     id    seedPertInt;
  37.     id    seedIntFlag;
  38.     id    seedPertVal;
  39.     id    seedValFlag;
  40.     id    magField;
  41.     id    magFlag;
  42.     id    colInterval;
  43.     id    colFlag;
  44.     id    randomFlag;
  45.     id    funcAuto;
  46.     id    funcButton;
  47.     id    colorButton;
  48.     id    aFlag;
  49.     id    bFlag;
  50.     id    cFlag;
  51.     id    a1Flag;
  52.     id    b1Flag;
  53.     id    c1Flag;
  54.     id    afFlag;
  55.     id    bfFlag;
  56.     id    cfFlag;
  57.     id    useFileFlag;
  58.     id displaceX;
  59.     id displaceY;
  60.  
  61.     int    Ncolors, Function;
  62.     int     mxp, np;             /* max in-range points, in-range points    */
  63.     int     mxP, nP;             /* max total points,    total points       */
  64.     int     nC, nc;              /* color-change interval (points)          */
  65.     int     nD, nd;       /* dynam flush buffer interval (points)    */
  66.     int     Pn, pn;              /* seed perturbation interval (points)     */
  67.     double  Pv;                    /* seed perturbation value                 */
  68.     double  A, B, C;           /* hopalong parameters                     */
  69.     int     Color;                 /* non-zero if color                       */
  70.     int     Randomcolor;           /* non-zero for randomized color sequences */
  71.     double  Zf;                    /* magnification factor                    */
  72.     int     cx, cy, ix, iy, mxX, mxY, W, H, moveX, moveY, color;
  73.     double     x, y, x1;
  74.     long    Ranfseed;        
  75.     int        streamPos, isPaused;
  76.  }
  77.  
  78. + initialize;
  79.  
  80. - free;
  81. - initFrame:(NXRect *)frameRect;
  82. - sizeTo:(NXCoord)width :(NXCoord)height;
  83. - drawSelf:(const NXRect *)rects :(int)rectCount;
  84. - windowWillMiniaturize:sender toMiniwindow:miniwindow;
  85.  
  86. /* Inherited from BackView */
  87. - inspector:sender;
  88. - inspectorWillBeRemoved;
  89. - oneStep;
  90. - (BOOL) useBufferedWindow;
  91. - didLockFocus;
  92.  
  93. /* Inspector panel methods */
  94. - pause:sender;
  95. - useFile:sender;
  96. - remember:sender;
  97. - setHopA:sender;
  98. - setHopB:sender;
  99. - setHopC:sender;
  100. - setMagnification:sender;
  101. - setSeedInt:sender;
  102. - setSeedVal:sender;
  103. - setColChange:sender;
  104. - setRandomColor:sender;
  105. - setMaxTot:sender;
  106. - setMaxIn:sender;
  107. - setDisplacement:sender;
  108. - changeColorMode:sender;
  109. - convertColors;
  110. - changeFunc:sender;
  111. - changeDynam:sender;
  112. - makeNewDynam:(int)num;
  113. - newOne:sender;
  114.  
  115. @end
  116.  
  117.  
  118.